home *** CD-ROM | disk | FTP | other *** search
- /*
- Library for ftpd clients.(libftp)
- Copyright by Oleg Orel
- All rights reserved.
-
- This library is desined for free, non-commercial software creation.
- It is changeable and can be improved. The author would greatly appreciate
- any advises, new components and patches of the existing programs.
- Commercial usage is also possible with participation of it's author.
-
-
-
- */
-
- #include "FtpLibrary.h"
-
- main(int a,char **b)
- {
- FILE *out,*in;
- int c;
- extern int ftplib_debug;
-
-
- FtplibDebug(1);
-
- if ( a != 3 )
- {
- fprintf(stderr,
- "Usage: %s node/user/pass:input-file node/user/pass:out-file\n",
- b[0]);
- exit(1);
- }
-
- if ((in=FtpFullOpen(b[1],"rb"))==NULL)
- perror(b[1]),exit(1);
- if ((out=FtpFullOpen(b[2],"w"))==NULL)
- perror(b[2]),exit(1);
-
-
- while((c=getc(in))!=EOF)
- putc(c,out);
- FtpFullClose(in);
- FtpFullClose(out);
- }
-